You are here: Symbol Reference > Monnit.Mine Namespace > Gateway Class > Gateway Constructor > Gateway.Gateway Constructor (uint, eGatewayType, string, string, string, int, byte[], byte[], byte[], double, bool, double, bool, string, string, string, string, string)
Gateway.Gateway Constructor (uint, eGatewayType, string, string, string, int, byte[], byte[], byte[], double, bool, double, bool, string, string, string, string, string)
Gateway Class  Gateway Members  Gateway Constructor  Send Feedback

Presets these properties 

GatewayType GatewayFirmwareVersion RadioFirmwareVersion Host Port PreSharedEncryptionKey 

You can selectively set these properties ReportInterval (Default: 5) ObserveAware (Default: true) PollInterval (Default: 0 Not Enabled) HasUrgentTraffic (Default: false) GatewayIP (Default: "0.0.0.0" Use DHCP) GatewaySubnet (Default: "0.0.0.0") DefaultRouterIP (Default: "0.0.0.0") GatewayDNS (Default: "0.0.0.0") SecondaryDNS (Default: "0.0.0.0") 

Sets all other properties to default values

Syntax
C++
C#
Visual Basic
Gateway(unsigned gatewayID, eGatewayType gatewayType, string gatewayFirmwareVersion, string radioFirmwareVersion, string hostAddress, int port, byte[] preSharedEncryptionKey, byte[] encryptionKey, byte[] encryptionIV, double reportInterval = 5, bool observeAware = true, double pollInterval = 0, bool hasUrgentTraffic = false, string gatewayIP = "0.0.0.0", string gatewaySubnet = "0.0.0.0", string defaultRouterIP = "0.0.0.0", string gatewayDNS = "0.0.0.0", string secondaryDNS = "0.0.0.0");
Parameters 
Description 
uint gatewayID 
Numerical identifier of the gateway. 
eGatewayType gatewayType 
Type of gateway. 
string gatewayFirmwareVersion 
Gateway firmware version. 
string radioFirmwareVersion 
Radio firmware version. 
string hostAddress 
IP Address or DNS resolvable host name address the gateway uses to communicate to the server. 
int port 
Port the gateway will use to communicate to the server. 
byte[] preSharedEncryptionKey 
Static pre-shared key for initializing encryption handshake 
byte[] encryptionKey 
Encryption key generated during handshake, if server is restarted or multiple server instances are configured this key needs to match across all instances or the gateway will have to re initialize its security handshake 
byte[] encryptionIV 
Initialization vector generated during handshake, if server is restarted or multiple server instances are configured this key needs to match across all instances or the gateway will have to re initialize its security handshake 
double reportInterval 
Interval in minutes gateway communicates. (Default: 5) 
bool observeAware 
Triggers communication on aware messages from sensors. (Default: true) 
double pollInterval 
Interval the gateway polls the server to identify if urgent messages need to be communicated to gateway. (Default: 0 Not Enabled) 
bool hasUrgentTraffic 
Indicates if the server currently has urgent traffic for the gateway. (Default: false) 
string gatewayIP 
IP the gateway will use on the local area network. (Default: "0.0.0.0" Use DHCP) 
string gatewaySubnet 
Subnet the gateway will use to communication on the local area network. (Default: "0.0.0.0") 
string defaultRouterIP 
Default router the gateway will send information to if it needs to communicate outside the local area network. (Default: "0.0.0.0") 
string gatewayDNS 
DNS server used to lookup server host names. (Not used is host is configured with IP Address.) (Default: "0.0.0.0") 
string secondaryDNS 
Secondary DNS server used to lookup host names if Primary DNS server is not available. (Default: "0.0.0.0")